package middle.id_1_100;

public class Lee12 {
    public String intToRoman(int num) {
        int[] nums={1000,900,500,400,100,90,50,40,10,9,5,4,1};
        String[] ss={"M","CM","D","CD","C","XC","L","XL","X","IX","V","IV","I"};
        String res = "";
        for (int i = 0; i < 13; i++) {
            while (num >= nums[i]) {
                res += ss[i];
                num -= nums[i];
            }
        }
        return res;

    }
}
